package com.gdit.comm.enums;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;

/**
 * 关系枚举类
 *
 * @author fgba
 */
@AllArgsConstructor
@NoArgsConstructor
public enum Relation {
    MOTHER(0, "母亲"), FATHER(1, "父亲"), OTHER(2, "其他");

    @EnumValue
    private Integer code;
    //标记响应json值
    @JsonValue
    private String name;

    public Integer getCode() {
        return code;
    }

    public String getName() {
        return name;
    }

}
